import { RouteRecordRaw } from "vue-router"
const routerName = 'order';
import Layout from "@/layout/index.vue";
import {BookmarksSharp,BeerSharp,CubeOutline} from "@vicons/ionicons5";
import { renderIcon } from "@/utils";

const routes:Array<RouteRecordRaw> = [
{ 
    path:'/order',
    name:routerName,
    component:Layout,
    redirect:'/order/list',
    meta:{
      title:'订单管理',
      icon:renderIcon(BookmarksSharp),
      sort:2
    },
    children:[
      {
        path:'list',
        name:`${routerName}_list`,
        meta:{
          title:'订单列表',
          icon:renderIcon(BeerSharp),
        },
        component:()=> import("@/views/Order/index.vue")

      },
      {
        path:'refund',
        name:`${routerName}_refund`,
         meta:{
          title:'退款列表',
          icon:renderIcon(CubeOutline)
        },
        component:()=> import("@/views/Order/refund.vue")

      }
    ]
  }
]

export default routes;